/**
 * Copyright &copy; 2015-2020 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
 */
package com.jeeplus.modules.address.entity;

import com.jeeplus.modules.member.entity.Member;
import javax.validation.constraints.NotNull;

import com.jeeplus.core.persistence.DataEntity;
import com.jeeplus.common.utils.excel.annotation.ExcelField;

/**
 * 用户地址Entity
 * @author freedom
 * @version 2020-08-07
 */
public class Address extends DataEntity<Address> {
	
	private static final long serialVersionUID = 1L;
	private Member member;		// 用户
	private String name;		// 收件人
	private String address;		// 收件地址
	private String mobile;		// 收件人手机号
	private String isdefault;		// 是否默认   ---0：不默认；1：默认

	//前端用   省市区
	private String province;
	//前端用    详细地址
	private String detail;
	
	public Address() {
		super();
	}

	public Address(String id){
		super(id);
	}

	@NotNull(message="用户不能为空")
	@ExcelField(title="用户", fieldType=Member.class, value="member.loginName", align=2, sort=1)
	public Member getMember() {
		return member;
	}

	public void setMember(Member member) {
		this.member = member;
	}
	
	@ExcelField(title="收件人", align=2, sort=2)
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	@ExcelField(title="收件地址", align=2, sort=3)
	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}
	
	@ExcelField(title="收件人手机号", align=2, sort=4)
	public String getMobile() {
		return mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}
	
	@ExcelField(title="是否默认   ---0：不默认；1：默认", dictType="yes_no", align=2, sort=5)
	public String getIsdefault() {
		return isdefault;
	}

	public void setIsdefault(String isdefault) {
		this.isdefault = isdefault;
	}


	public String getProvince() {
		return province;
	}

	public void setProvince(String province) {
		this.province = province;
	}

	public String getDetail() {
		return detail;
	}

	public void setDetail(String detail) {
		this.detail = detail;
	}
}